package cn.com.dhcc.turbo.entity.registry.wapper;

import java.sql.ResultSet;
import java.sql.SQLException;

import org.springframework.jdbc.core.RowMapper;

import cn.com.dhcc.app.core.handler.dbhandler.WappedResultSet;
import cn.com.dhcc.turbo.entity.registry.NodePermission;

public class NodePermissionRowWapper implements RowMapper<NodePermission> {
	@Override
	public NodePermission mapRow(ResultSet rss, int rowNum) throws SQLException {
		WappedResultSet rs = new WappedResultSet(rss);
		NodePermission vo = new NodePermission();
		vo.setRegionNode(rs.getString("ad_cd"));
		vo.setRegionName(rs.getString("ad_nm"));
		vo.setIsMgr(rs.getString("ismgr"));
		vo.setRegionCodesToMgr(rs.getString("ad_cd_to_mgr"));
		vo.setMtime(rs.getDate("mtime"));
		vo.setRemark(rs.getString("remark"));
		return vo;
	}
}
